package com.scsj.supermarket.adapter;

import android.content.Context;
import android.support.annotation.Nullable;
import android.view.LayoutInflater;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.scsj.supermarket.R;
import com.scsj.supermarket.bean.CommAlreadyBean;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 *  银行卡列表
 */

public class MyBankListAdapter extends BaseQuickAdapter<CommAlreadyBean,BaseViewHolder> {

    private Context context;
    private LayoutInflater mLayoutInflater;
    public  boolean isEditStatus=false;
    private Map<Integer, Boolean> map = new HashMap<>();
    private boolean onBind;
    private int checkedPosition = -1;
    private String bankName;
    private String bankType;
    private String bankNum;
    private String bankLogoUrl;

    public MyBankListAdapter(@Nullable List<CommAlreadyBean> data) {
        super(R.layout.item_mine_banklist_layout, data);
    }

    @Override
    protected void convert(BaseViewHolder helper, CommAlreadyBean item) {
        if (helper.getLayoutPosition()==0){

            helper.setVisible(R.id.defaut_bank_card,true);

        }else {
            helper.setVisible(R.id.defaut_bank_card,false);
        }
    }
}
